<?php
class PNProvince extends PNObjectEx {
  function PNProvince($init=null, $where='')
  {
    $this->PNObject();

    $this->_objType       = 'icarrent_province';
    $this->_objField      = 'id';
    $this->_objPath       = 'form';

    $this->_init($init, $where);
  }


  function insertPostProcess(){

    
        

    
    for($i=1; $i<=count($this->_objData["airport"]); $i++){
    
      $this->_objData["airport"][$i]["prov_id"] = $this->_objData[id];
    }
    
    //print_r($this->_objData["airport"]); exit;       
    $objects = $this->_objData["airport"];
    $tablename = "icarrent_province_airport";
    
    DBUtil::insertObjectArray($objects, $tablename, 'id', false, false);
    
    
 
  }
  
  
  function updatePostProcess(){
    
  /*  
    //$this->_objData[id];    
    //print_r($this->_objData); exit;
    
    
    $objects = $this->objData["airport"];
    $tablename = "icarrent_province_airport";
    
    DBUtil::insertObjectArray($objects, $tablename, 'id', false, false);
        
    
    DBUtil::updateObject( object The &$object, tablename $tablename, [where $where = ''], [idcolumn $idcolumn = 'id'], [force $force = false], [updateid $updateid = false])    
    */
  }  
}